{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "9b3f3885",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "现在的时间是： 2021/09/21 17:09 Tuesday\n",
      "请输入要查询的星期:2\n",
      "请输入需要查询的时间(省略中间字符，只要输入完整的时间值)：1520\n",
      "现在是 新媒体时代的评论 的上课时间\n"
     ]
    }
   ],
   "source": [
    "# week03 课程表练习+week04继续修改\n",
    "import time\n",
    "now_time1 = time.strftime(\"%Y/%m/%d\")\n",
    "now_time2 = time.strftime(\"%H:%M\")\n",
    "now_time3 = time.strftime(\"%A\")\n",
    "print(\"现在的时间是：\",now_time1,now_time2,now_time3)\n",
    "\n",
    "weekday=int(input(\"请输入要查询的星期:\")) \n",
    "classtime=int(input(\"请输入需要查询的时间(省略中间字符，只要输入完整的时间值)：\"))\n",
    "if weekday == 1 :\n",
    "    if 1035 < classtime < 1200 :\n",
    "        print(\"现在是 大英 的上课时间\")\n",
    "    elif 1430 < classtime < 1610 :\n",
    "        print(\" 现在是 Python语言 的上课时间\")\n",
    "    else:\n",
    "        print(\"现在没有课程安排\")\n",
    "elif weekday == 2 :\n",
    "    if 945 < classtime <1200:\n",
    "        print(\"现在是 创业基础（实践）的上课时间\")\n",
    "    elif 1430 < classtime < 1655:\n",
    "         print(\"现在是 新媒体时代的评论 的上课时间\")\n",
    "    elif 1845 < classtime < 2010:\n",
    "        print(\"现在是 法国文学导读 的上课时间\")\n",
    "    else:\n",
    "        print(\"没有课程安排\")\n",
    "elif weekday == 3 :\n",
    "    if 945 < classtime < 1200:\n",
    "        print(\"现在是 融合新闻学 的上课时间\")\n",
    "    elif 1845 < classtime < 2010:\n",
    "        print(\"现在是 大英 的上课时间\")\n",
    "    else:\n",
    "        print(\"该时间没有课程安排\")\n",
    "elif weekday == 4 :\n",
    "    if 1035 < classtime < 1200:\n",
    "        print(\"现在是 毛概实践 的上课时间\")\n",
    "    else:\n",
    "        print(\"该时间没有课程安排\")\n",
    "elif weekday == 5 :\n",
    "    if 800 < classtime < 925:\n",
    "        print(\"现在是 AI软件基础应用 的上课时间\")\n",
    "    elif 1035 < classtime < 1200:\n",
    "        print(\"现在是 体育（武术）的上课时间\")\n",
    "    elif 1430 < classtime < 1655:\n",
    "        print(\"现在是 毛概理论 的上课时间\")\n",
    "    else:\n",
    "        print(\"该时间没有课程安排\")\n",
    "else:\n",
    "    print(\"周末\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "fad600ea",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.8.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
